package com.lizhi.yun.db.sfrobot.entity;

import com.lizhi.mybatis.boot.Description;
import com.lizhi.yun.db.sfrobot.common.RobotActionAxisMode;
import com.lizhi.yun.db.sfrobot.common.RobotActionBuildMode;
import com.lizhi.yun.db.sfrobot.common.RobotActionRunMode;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.ToString;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;

/**
 * 处方项目
 */
@Data
@ToString
@Entity
@Table(name = "his_center_prescription_action")
@Description("处方动作")
public class PrescriptionAction extends AbstractHisEntity {

    @Id
    @Column(length = 30)
    @Description("lid")
    public String lid;

    @Description("记录id")
    public Long id;

    @Column
    @Description("处方id")
    public Long prescriptionId;

    /**
     * 患者id
     */
    @Column
    @Description("患者id")
    public Long patientId;

    /**
     * 训练动作执行集合
     */
    @Column(length = 10000)
    @Description("训练动作执行集合")
    public String command;

    /**
     * 单次完成的运行时间(s)
     */
    @Column
    @Description("单次训练时长")
    public int duration;

    /**
     * 单次完成的运行时间(s)默认
     */
    @Column
    @Description("默认单次训练时长")
    public int defaultDuration;

    /**
     * 主动，被动
     *
     * @see RobotActionRunMode
     */
    @Column
    @Description("运动方式")
    public int runModeId;

    @Column(length = 20)
    @Description("运动方式名称")
    public String runModeText;

    /**
     * 轴类型
     *
     * @see RobotActionAxisMode
     */
    @Column
    @Description("轴类型id")
    public int axisModeId;

    @Column(length = 20)
    @Description("轴类型名称")
    public String axisModeText;

    /**
     * 来源，系统自建，医师创建
     *
     * @see RobotActionBuildMode
     */
    @Column
    @Description("处方创建来源id")
    public int buildModeId;

    @Column(length = 20)
    @Description("处方创建来源名称")
    public String buildModeText;

    /**
     * 版本号
     */
    @Column
    @Description("版本号")
    public int version;

    @Column
    @Description("排序号")
    public int sortIndex;

    /**
     * 最大角度
     */
    @Column
    @Description("动作最大角度")
    public Float maxAngle;

    /**
     * 最小角度
     */
    @Column
    @Description("动作最小角度")
    public Float minAngle;

    /**
     * 调整幅度
     */
    @Column
    @Description("动作调整幅度")
    public Float adjustRange;

    /**
     * 速度 n/s
     */
    @Column
    @Description("移动速度")
    public Float moveSpeed;

    /**
     * 机器人动作Id
     */
    @Column
    @Description("训练动作id")
    public Long robotActionId;

    /**
     * 机器人动作名称
     */
    @Column(length = 50)
    @Description("训练动作名称")
    public String robotActionText;

    @Column(length = 500)
    @Description("处方动作图片")
    public String image;

    /**
     * 轴号，与评估的项里的轴号进行对应
     */
    @Column
    @Description("轴号")
    public Integer axis;

    @Column(length = 20)
    @Description("创建时间")
    public String createTime;

    /*云管需要的数据*/
    @ApiModelProperty(value = "医院ID")
    private String hospitalId;

    @ApiModelProperty(value = "系统ID")
    private String hospitalSystemId;
}
